#ifndef RTW_HEADER_bms_Slave_h_
#define RTW_HEADER_bms_Slave_h_
#ifndef bms_Slave_COMMON_INCLUDES_
#define bms_Slave_COMMON_INCLUDES_
#include <math.h>
#include "rtwtypes.h"
#endif

#include "bms_Slave_types.h"
#include "can_message.h"
#include "AFE_SignalType.h"
#include "SOC_GX.h"
#include "Balance.h"
#include "Alarm_Recov_sys.h"
#include "Alarm_Recov_sys_cell.h"
#include "Alarm_nonRecov_sys.h"
#include "ASW_SignalAdapt.h"
#include "ABI_OSEK.h"
#include "APP_BSW.h"
#include <string.h>
#include "rtGetInf.h"
#include "rt_nonfinite.h"

#include "calPrms.h"
#include "ASW_Signal.h"

#ifndef rtmGetErrorStatus
#define rtmGetErrorStatus(rtm)         ((rtm)->errorStatus)
#endif

#ifndef rtmSetErrorStatus
#define rtmSetErrorStatus(rtm, val)    ((rtm)->errorStatus = (val))
#endif

#ifndef rtmGetErrorStatusPointer
#define rtmGetErrorStatusPointer(rtm)  ((const char_T **)(&((rtm)->errorStatus)))
#endif

#include "Rte.h"

typedef struct {
  CAN_DATATYPE BMS_Chrg_Request_Pack;
  CAN_DATATYPE CMC_Chrger_Cell_1_Pack;
  CAN_DATATYPE CMC_Chrger_Cell_2_Pack;
  CAN_DATATYPE CMC_Chrger_Cell_3_Pack;
  CAN_DATATYPE CMC_Chrger_Cell_4_Pack;
  CAN_DATATYPE CMC_Chrger_Cell_5_Pack;
  CAN_DATATYPE CMC_Chrger_CellTemp_Pack;
  CAN_DATATYPE CMC_Chrger_Statistics_Pack;
  CAN_DATATYPE CMC_Chrger_Alarm_Pack;
  CAN_DATATYPE CMC_Chrger_BatteryID1_Pack;
  CAN_DATATYPE CMC_Chrger_BatteryID2_Pack;
  CAN_DATATYPE CMC_Chrger_BatteryID3_Pack;
  CAN_DATATYPE CMC_Chrger_Factory_Param_Pack;
  CAN_DATATYPE CMC_CellV_1_Pack;
  CAN_DATATYPE CMC_CellV_2_Pack;
  CAN_DATATYPE CMC_CellV_3_Pack;
  CAN_DATATYPE CMC_CellV_4_Pack;
  CAN_DATATYPE BalaSta_CycleCapacity_Pack;
  CAN_DATATYPE CMC_CellT_SOC_Pack;
  CAN_DATATYPE Max_Con_Current_Pack;
  CAN_DATATYPE CMC_Current_Falt_Pack;
  CAN_DATATYPE Chrger_CMC_Wake_Pack;
  CAN_DATATYPE Chrger_CMC_Chrg_Pack;
  CAN_DATATYPE BMU_CMD_Pack;
  CAN_DATATYPE Para_Set_BMS_Pack;
  AFE_SignalType AFE_Signal;
  real_T Open_The_Barn_door;
  real_T Chrg_Mark;
  real_T Chrger_Alarm;
  real_T BMU_Life;
  real_T Balance_Cmd;
  real_T CMD_Pack_ID;
  real_T ErrorCode_Clear;
  real_T Relay_Contrl_Single;
  real_T Relay_Contrl;
  real_T BMS_BatSOC_Actl_Set;
  real_T BMS_BatSOC_Actl_Set_Valid;
  real_T BMS_BatSOC_Rpt_Set;
  real_T BMS_BatSOC_Rpt_Set_Valid;
  real_T BMS_CurrFixCoeff_Set;
  real_T BMS_CurrFixCoeff_Set_Valid;
  real_T BMS_CurrOffset_Set;
  real_T BMS_CurrOffset_Set_Valid;
  uint32_T BMS_Chrg_Request_ID;
  uint32_T CMC_Chrger_Cell_1_ID;
  uint32_T CMC_Chrger_Cell_2_ID;
  uint32_T CMC_Chrger_Cell_3_ID;
  uint32_T CMC_Chrger_Cell_4_ID;
  uint32_T CMC_Chrger_Cell_5_ID;
  uint32_T CMC_Chrger_CellTemp_ID;
  uint32_T CMC_Chrger_Statistics_ID;
  uint32_T CMC_Chrger_Alarm_ID;
  uint32_T CMC_Chrger_BatteryID1_ID;
  uint32_T CMC_Chrger_BatteryID2_ID;
  uint32_T CMC_Chrger_BatteryID3_ID;
  uint32_T CMC_Chrger_Factory_Param_ID;
  uint32_T CMC_CellV_1_ID;
  uint32_T CMC_CellV_2_ID;
  uint32_T CMC_CellV_3_ID;
  uint32_T CMC_CellV_4_ID;
  uint32_T BalaSta_CycleCapacity_ID;
  uint32_T CMC_CellT_SOC_ID;
  uint32_T Max_Con_Current_ID;
  uint32_T Balance_o3;
  uint32_T CMC_Current_Falt_ID;
  uint32_T Balance_State;
  real32_T SOH;
  real32_T Real_SOC_Max;
  real32_T SOC_Act;
  real32_T SOC_Rpt;
  real32_T Switch9;
  real32_T Con_AllowChrg_Current;
  real32_T Con_AllowDisChrg_Current;
  real32_T SOC_Ave;
  real32_T CurrOffset_Cal_Add;
  real32_T Gain3;
  real32_T Gain24;
  real32_T Gain4;
  real32_T Gain5;
  real32_T Gain6;
  real32_T Gain7;
  real32_T Gain8;
  real32_T Gain9;
  real32_T Gain10;
  real32_T Gain11;
  real32_T Gain12;
  real32_T Gain13;
  real32_T Gain14;
  real32_T Gain15;
  real32_T Gain16;
  real32_T Gain17;
  real32_T Gain18;
  real32_T Gain19;
  real32_T Gain20;
  real32_T Gain21;
  real32_T Gain22;
  real32_T Gain23;
  real32_T Gain;
  real32_T Gain2;
  real32_T Gain1;
  real32_T Gain11_o;
  real32_T Gain10_b;
  real32_T Gain9_l;
  real32_T Gain8_e;
  real32_T Gain_m;
  real32_T DC_ChrgVol;
  real32_T CellT_AD_IN[10];
  real32_T BMS_BatSOC_Actl_Set_f;
  real32_T BMS_BatSOC_Rpt_Set_o;
  int32_T Current;
  int32_T BMS_CurrOffset_Set_i;
  uint16_T Cycle_Num;
  uint16_T CellV_OUT[32];
  uint16_T CellV_OUT_p[32];
  uint16_T CellV_mean;
  uint16_T CellV_max;
  uint16_T CellV_min;
  uint16_T Selector23;
  uint16_T Selector24;
  uint16_T Selector31;
  uint16_T Selector32;
  uint16_T Selector33;
  uint16_T Selector34;
  uint16_T Selector35;
  uint16_T Selector36;
  uint16_T Selector37;
  uint16_T Selector38;
  uint16_T Selector25;
  uint16_T Selector26;
  uint16_T Selector27;
  uint16_T Selector28;
  uint16_T Selector29;
  uint16_T Selector30;
  uint16_T ErrorCode_Clear_c;
  uint16_T CellV_IN[32];
  int16_T CellT_mean;
  int16_T CellT_max;
  int16_T CellT_min;
  int16_T CellT_out[6];
  int16_T CellT_OUT[10];
  int16_T Selector20;
  int16_T Selector21;
  int16_T Selector22;
  uint8_T CellV_TgtReach;
  uint8_T DB_OCV_Condition;
  uint8_T Chrg_Sta;
  uint8_T BMS_PwrTrainConnectSta;
  uint8_T Relay_En;
  uint8_T ShiftArithmetic;
  uint8_T BMS_Chrg_Request_Data[8];
  uint8_T BMS_Chrg_Request_Len;
  uint8_T CMC_Chrger_Cell_1_Data[8];
  uint8_T CMC_Chrger_Cell_1_Len;
  uint8_T CMC_Chrger_Cell_2_Data[8];
  uint8_T CMC_Chrger_Cell_2_Len;
  uint8_T CMC_Chrger_Cell_3_Data[8];
  uint8_T CMC_Chrger_Cell_3_Len;
  uint8_T CMC_Chrger_Cell_4_Data[8];
  uint8_T CMC_Chrger_Cell_4_Len;
  uint8_T CMC_Chrger_Cell_5_Data[8];
  uint8_T CMC_Chrger_Cell_5_Len;
  uint8_T CMC_Chrger_CellTemp_Data[8];
  uint8_T CMC_Chrger_CellTemp_Len;
  uint8_T CMC_Chrger_Statistics_Data[8];
  uint8_T CMC_Chrger_Statistics_Len;
  uint8_T CMC_Chrger_Alarm_Data[8];
  uint8_T CMC_Chrger_Alarm_Len;
  uint8_T CMC_Chrger_BatteryID1_Data[8];
  uint8_T CMC_Chrger_BatteryID1_Len;
  uint8_T CMC_Chrger_BatteryID2_Data[8];
  uint8_T CMC_Chrger_BatteryID2_Len;
  uint8_T CMC_Chrger_BatteryID3_Data[8];
  uint8_T CMC_Chrger_BatteryID3_Len;
  uint8_T CMC_Chrger_Factory_Param_Data[8];
  uint8_T CMC_Chrger_Factory_Param_Len;
  uint8_T CMC_CellV_1_Data[8];
  uint8_T CMC_CellV_1_Len;
  uint8_T CMC_CellV_2_Data[8];
  uint8_T CMC_CellV_2_Len;
  uint8_T CMC_CellV_3_Data[8];
  uint8_T CMC_CellV_3_Len;
  uint8_T CMC_CellV_4_Data[8];
  uint8_T CMC_CellV_4_Len;
  uint8_T BalaSta_CycleCapacity_Data[8];
  uint8_T BalaSta_CycleCapacity_Len;
  uint8_T Switch1;
  uint8_T CMC_CellT_SOC_Data[8];
  uint8_T CMC_CellT_SOC_Len;
  uint8_T Max_Con_Current_Data[8];
  uint8_T Max_Con_Current_Len;
  uint8_T Bal_State;
  uint8_T Bal_Cmd[32];
  uint8_T Switch;
  uint8_T CMC_Current_Falt_Data[8];
  uint8_T CMC_Current_Falt_Len;
  uint8_T Err_Level_a;
  uint8_T BMS_Error_Code;
  uint8_T CMC_Alarm_1;
  uint8_T CMC_Alarm_2;
  uint8_T CMC_Alarm_4;
  uint8_T Err_Level_n;
  uint8_T DTC_ErrCode[80];
  uint8_T CMC_Alarm_3;
  uint8_T Current_Out;
  uint8_T ChrgMode;
  uint8_T Open_The_Barn_door_c;
  uint8_T Chrger_Alarm_e;
  uint8_T Chrg_Mark_a;
  uint8_T Relay_Contrl_Single_h;
  uint8_T Relay_Contrl_i;
  uint8_T CMD_Pack_ID_o;
  uint8_T Para_Set_BMS[8];
  uint8_T Chrger_CMC_Chrg_Data[8];
  uint8_T Chrger_CMC_Wake_Data[8];
  uint8_T BMU_CMD_Data[8];
  uint8_T BMS_CurrOffset_Set_Valid_k;
  uint8_T BMS_BatSOC_Actl_Set_Valid_l;
  uint8_T BMS_BatSOC_Rpt_Set_Valid_a;
  boolean_T CellT_Valid;
  boolean_T LogicalOperator3;
  boolean_T LogicalOperator9;
  boolean_T RelationalOperator1;
  boolean_T UnitDelay17;
  boolean_T UnitDelay21;
  boolean_T CellV_Connect[32];
  boolean_T SOC_Correct_Flag;
  boolean_T Alarm_flg;
  boolean_T Alarm_flg_m;
  boolean_T Alarm_flg_j;
  boolean_T Alarm_flg_l;
  boolean_T Alarm_flg_jr;
  boolean_T Alarm_flg_a;
  boolean_T Alarm_flg_h;
  boolean_T Alarm_flg_e;
  boolean_T ChrgMOS_Open_Cmd;
  boolean_T DisChrgMOS_Open_Cmd;
  boolean_T ChrgPower_Limit_0;
  boolean_T DisChrgPower_Limit_0;
  boolean_T ChrgPower_Limit_50;
  boolean_T DisChrgPower_Limit_50;
  boolean_T AC_ChrgDisable;
  boolean_T Alarm_flg_k;
  boolean_T Alarm_flg_g;
  boolean_T Alarm_flg_c;
  boolean_T Alarm_flg_as;
  boolean_T Alarm_flg_gx;
  boolean_T Alarm_flg_jz;
  boolean_T Alarm_flg_hj;
  boolean_T Alarm_flg_n;
  boolean_T Alarm_flg_aa;
  boolean_T LogicalOperator1;
  boolean_T Alarm_flg_d;
  boolean_T Alarm_flg_br;
  boolean_T Alarm_flg_a3;
  boolean_T Alarm_flg_p;
  boolean_T Alarm_flg_li;
  boolean_T Alarm_flg_dc;
  boolean_T Alarm_flg_nq;
  boolean_T Alarm_flg_jq;
  boolean_T Alarm_flg_c0;
  boolean_T Alarm_flg_df;
  boolean_T Alarm_flg_c5;
  boolean_T Alarm_flg_oe;
  boolean_T Alarm_flg_n1;
  boolean_T Alarm_flg_nt;
  boolean_T Alarm_flg_p0;
  boolean_T Alarm_flg_ll;
  boolean_T Alarm_flg_ja;
  boolean_T Alarm_flg_dr;
  boolean_T Alarm_flg_c3;
  boolean_T Alarm_flg_ha;
  boolean_T Alarm_flg_lh;
  boolean_T Alarm_flg_ne;
  boolean_T Alarm_flg_jl;
  boolean_T LogicalOperator20;
} B_bms_Slave_T;

typedef struct {
  real32_T UnitDelay8_DSTATE;
  real32_T UnitDelay10_DSTATE;
  real32_T UnitDelay11_DSTATE;
  real32_T UnitDelay24_DSTATE;
  real32_T UnitDelay25_DSTATE;
  real32_T UnitDelay27_DSTATE;
  real32_T UnitDelay5_DSTATE;
  real32_T UnitDelay15_DSTATE;
  real32_T UnitDelay4_DSTATE;
  real32_T UnitDelay10_DSTATE_m;
  real32_T UnitDelay5_DSTATE_a;
  real32_T UnitDelay3_DSTATE;
  real32_T UnitDelay1_DSTATE;
  real32_T UnitDelay3_DSTATE_e;
  real32_T UnitDelay1_DSTATE_a;
  real32_T UnitDelay_DSTATE_g;
  real32_T UnitDelay_DSTATE_i;
  real32_T UnitDelay_DSTATE_m;
  real32_T UnitDelay_DSTATE_l;
  real32_T UnitDelay1_DSTATE_e;
  real32_T UnitDelay3_DSTATE_p;
  uint32_T UnitDelay35_DSTATE;
  real32_T SOC_Store;
  real32_T Cur;
  real32_T SOC_Store_m;
  uint32_T T;
  uint32_T T_e;
  uint32_T Mileage_Store;
  int_T BMS_Chrg_Request_Pack_ModeSigna;
  int_T BMS_Chrg_Request_Unpack_ModeSig;
  int_T BMS_Chrg_Request_Unpack_StatusP;
  int_T CMC_Chrger_Cell_1_Pack_ModeSign;
  int_T CMC_Chrger_Cell_1_Unpack_ModeSi;
  int_T CMC_Chrger_Cell_1_Unpack_Status;
  int_T CMC_Chrger_Cell_2_Pack_ModeSign;
  int_T CMC_Chrger_Cell_2_Unpack_ModeSi;
  int_T CMC_Chrger_Cell_2_Unpack_Status;
  int_T CMC_Chrger_Cell_3_Pack_ModeSign;
  int_T CMC_Chrger_Cell_3_Unpack_ModeSi;
  int_T CMC_Chrger_Cell_3_Unpack_Status;
  int_T CMC_Chrger_Cell_4_Pack_ModeSign;
  int_T CMC_Chrger_Cell_4_Unpack_ModeSi;
  int_T CMC_Chrger_Cell_4_Unpack_Status;
  int_T CMC_Chrger_Cell_5_Pack_ModeSign;
  int_T CMC_Chrger_Cell_5_Unpack_ModeSi;
  int_T CMC_Chrger_Cell_5_Unpack_Status;
  int_T CMC_Chrger_CellTemp_Pack_ModeSi;
  int_T CMC_Chrger_CellTemp_Unpack_Mode;
  int_T CMC_Chrger_CellTemp_Unpack_Stat;
  int_T CMC_Chrger_Statistics_Pack_Mode;
  int_T CMC_Chrger_Statistics_Unpack_Mo;
  int_T CMC_Chrger_Statistics_Unpack_St;
  int_T CMC_Chrger_Alarm_Pack_ModeSigna;
  int_T CMC_Chrger_Alarm_Unpack_ModeSig;
  int_T CMC_Chrger_Alarm_Unpack_StatusP;
  int_T CMC_Chrger_BatteryID1_Pack_Mode;
  int_T CMC_Chrger_BatteryID1_Unpack_Mo;
  int_T CMC_Chrger_BatteryID1_Unpack_St;
  int_T CMC_Chrger_BatteryID2_Pack_Mode;
  int_T CMC_Chrger_BatteryID2_Unpack_Mo;
  int_T CMC_Chrger_BatteryID2_Unpack_St;
  int_T CMC_Chrger_BatteryID3_Pack_Mode;
  int_T CMC_Chrger_BatteryID3_Unpack_Mo;
  int_T CMC_Chrger_BatteryID3_Unpack_St;
  int_T CMC_Chrger_Factory_Param_Pack_M;
  int_T CMC_Chrger_Factory_Param_Unpack;
  int_T CMC_Chrger_Factory_Param_Unpa_e;
  int_T CMC_CellV_1_Pack_ModeSignalID;
  int_T CMC_CellV_1_Unpack_ModeSignalID;
  int_T CMC_CellV_1_Unpack_StatusPortID;
  int_T CMC_CellV_2_Pack_ModeSignalID;
  int_T CMC_CellV_2_Unpack_ModeSignalID;
  int_T CMC_CellV_2_Unpack_StatusPortID;
  int_T CMC_CellV_3_Pack_ModeSignalID;
  int_T CMC_CellV_3_Unpack_ModeSignalID;
  int_T CMC_CellV_3_Unpack_StatusPortID;
  int_T CMC_CellV_4_Pack_ModeSignalID;
  int_T CMC_CellV_4_Unpack_ModeSignalID;
  int_T CMC_CellV_4_Unpack_StatusPortID;
  int_T BalaSta_CycleCapacity_Pack_Mode;
  int_T BalaSta_CycleCapacity_Unpack_Mo;
  int_T BalaSta_CycleCapacity_Unpack_St;
  int_T CMC_CellT_SOC_Pack_ModeSignalID;
  int_T CMC_CellT_SOC_Unpack_ModeSignal;
  int_T CMC_CellT_SOC_Unpack_StatusPort;
  int_T Max_Con_Current_Pack_ModeSignal;
  int_T Max_Con_Current_Unpack_ModeSign;
  int_T Max_Con_Current_Unpack_StatusPo;
  int_T CMC_Current_Falt_Pack_ModeSigna;
  int_T CMC_Current_Falt_Unpack_ModeSig;
  int_T CMC_Current_Falt_Unpack_StatusP;
  int_T Chrger_CMC_Wake_UnPack_ModeSign;
  int_T Chrger_CMC_Wake_UnPack_StatusPo;
  int_T Chrger_CMC_Chrg_UnPack_ModeSign;
  int_T Chrger_CMC_Chrg_UnPack_StatusPo;
  int_T BMU_CMD_UnPack_ModeSignalID;
  int_T BMU_CMD_UnPack_StatusPortID;
  int_T Para_Set_BMS_UnPack_ModeSignalI;
  int_T Para_Set_BMS_UnPack_StatusPortI;
  int16_T UnitDelay1_DSTATE_m;
  uint16_T T_b;
  uint16_T counter;
  uint16_T Count;
  uint8_T UnitDelay36_DSTATE;
  uint8_T UnitDelay37_DSTATE;
  uint8_T UnitDelay4_DSTATE_b;
  uint8_T UnitDelay30_DSTATE;
  uint8_T UnitDelay7_DSTATE;
  uint8_T UnitDelay2_DSTATE;
  uint8_T UnitDelay26_DSTATE;
  uint8_T UnitDelay_DSTATE_j;
  uint8_T UnitDelay1_DSTATE_l;
  uint8_T UnitDelay2_DSTATE_b;
  uint8_T UnitDelay_DSTATE_e;
  uint8_T UnitDelay6_DSTATE;
  uint8_T UnitDelay2_DSTATE_f;
  uint8_T udTime1_DSTATE;
  uint8_T UnitDelay4_DSTATE_bl;
  uint8_T UnitDelay22_DSTATE;
  uint8_T UnitDelay34_DSTATE;
  uint8_T UnitDelay33_DSTATE;
  uint8_T UnitDelay1_DSTATE_f;
  uint8_T UnitDelay2_DSTATE_h;
  uint8_T UnitDelay5_DSTATE_n;
  uint8_T UnitDelay2_DSTATE_c;
  uint8_T UnitDelay3_DSTATE_m;
  uint8_T UnitDelay6_DSTATE_c;
  uint8_T UnitDelay_DSTATE_a;
  boolean_T UnitDelay13_DSTATE;
  boolean_T UnitDelay1_DSTATE_i;
  boolean_T UnitDelay18_DSTATE;
  boolean_T UnitDelay16_DSTATE;
  boolean_T UnitDelay17_DSTATE;
  boolean_T UnitDelay21_DSTATE;
  boolean_T UnitDelay9_DSTATE;
  boolean_T UnitDelay8_DSTATE_k;
  boolean_T UnitDelay15_DSTATE_e;
  boolean_T UnitDelay3_DSTATE_pu;
  boolean_T UnitDelay1_DSTATE_b;
  boolean_T UnitDelay2_DSTATE_a;
  uint8_T is_c37_bms_Slave;
  uint8_T is_active_c37_bms_Slave;
  uint8_T is_c13_bms_Slave;
  uint8_T is_active_c13_bms_Slave;
  uint8_T is_active_c16_bms_Slave;
  uint8_T is_c26_bms_Slave;
  uint8_T is_active_c26_bms_Slave;
  uint8_T is_active_c25_bms_Slave;
  uint8_T i;
  uint8_T FlsTperChip[10];
  uint8_T is_c14_bms_Slave;
  uint8_T Local_flag;
  uint8_T is_active_c14_bms_Slave;
  uint8_T T_n;
  uint8_T EEP_Data_b[41];
  uint8_T T_Rcv;
  uint8_T Para_Set_BMS_len;
  uint8_T Para_Set_BMS_Temp[8];
  uint8_T VIN_GET[17];
  uint8_T Chrger_CMC_Chrg_Len;
  uint8_T Chrger_CMC_Wake_len;
  uint8_T BMU_CMD_Len;
  uint8_T is_active_c9_bms_Slave;
  boolean_T Relay_Mode;
  boolean_T Diagnose_system_MODE;
  boolean_T DC_ChrgSig_MODE;
  boolean_T ChrgMode_Cal_MODE;
  MdlrefDW_SOC_GX_T SOC_InstanceData;
  MdlrefDW_Balance_T Balance_InstanceData;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_SOP_Dischrg_g;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_SOP_Dischrg;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_SOP_Rechrg_l;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_SOP_Rechrg;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_ReCellV;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_sys3_i;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_sys2;
  DW_Alarm_Recov_sys_T sf_Alarm_Recov_sys11;
  DW_Alarm_Recov_sys_cell_T sf_Alarm_Recov_sys10;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_sys9_m;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_sys8_p;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_sys7_d;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_sys6;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_sys5_l;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_sys4_i;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_sys3_l;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_sys2_f;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_sys1_g;
  DW_Alarm_nonRecov_sys_T sf_Alarm_nonRecov_sys7;
  DW_Alarm_nonRecov_sys_T sf_Alarm_nonRecov_sys6;
  DW_Alarm_nonRecov_sys_T sf_Alarm_nonRecov_sys5;
  DW_Alarm_nonRecov_sys_T sf_Alarm_nonRecov_sys4;
  DW_Alarm_nonRecov_sys_T sf_Alarm_nonRecov_sys3;
  DW_Alarm_nonRecov_sys_T sf_Alarm_nonRecov_sys2;
  DW_Alarm_nonRecov_sys_T sf_Alarm_nonRecov_sys1;
  DW_Alarm_nonRecov_sys_T sf_Alarm_nonRecov_sys_n;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_sys3_b;
  DW_Alarm_nonRecov_sys_T sf_Alarm_nonRecov_sys;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_sys9;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_sys8;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_sys7;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_sys5;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_sys4;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_sys3_j;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_sys2_b;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_sys19;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_sys18;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_sys17;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_sys16;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_sys15;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_sys14;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_sys13;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_sys12;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_sys11_k;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_sys10_i;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_sys1_j;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_sys;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_sys3_i1;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_sys1;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_sys3_f;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_sys3_iu;
  DW_Alarm_Recov_sys_bms_Slave_T sf_Alarm_Recov_sys3;
} DW_bms_Slave_T;

typedef struct {
  const uint16_T Width;
  const uint16_T Width_m;
  const uint16_T Width_d;
  const boolean_T RelationalOperator39;
  const boolean_T RelationalOperator383;
  const boolean_T LogicalOperator167;
  const boolean_T RelationalOperator4;
  const boolean_T RelationalOperator1;
  const boolean_T LogicalOperator1;
  const boolean_T RelationalOperator3;
  const boolean_T LogicalOperator15;
  const boolean_T LogicalOperator16;
  const boolean_T LogicalOperator77;
  const boolean_T Compare;
  const boolean_T Compare_i;
  const boolean_T RelationalOperator19;
  const boolean_T RelationalOperator12;
  const boolean_T LogicalOperator35;
  const boolean_T RelationalOperator1_j;
  const boolean_T RelationalOperator2;
  const boolean_T RelationalOperator14;
  const boolean_T RelationalOperator15;
  const boolean_T LogicalOperator11;
  const boolean_T RelationalOperator7[4];
  const boolean_T LogicalOperator12;
  const boolean_T RelationalOperator10;
  const boolean_T RelationalOperator8;
  const boolean_T VectorConcatenate2[8];
} ConstB_bms_Slave_T;

struct tag_RTM_bms_Slave_T {
  const char_T *errorStatus;
};

extern B_bms_Slave_T bms_Slave_B;
extern DW_bms_Slave_T bms_Slave_DW;
extern const ConstB_bms_Slave_T bms_Slave_ConstB;
extern uint8_T fc_r_cmcWake_flg_0;
extern uint8_T fc_r_bmu_cmd_flg_0;
extern uint8_T fc_r_ChrgData_flg_0;
extern uint8_T fc_r_ParaSet_flg_0;
extern void bms_Slave_initialize(void);
extern void bms_Slave_step(void);
extern void bms_Slave_terminate(void);
extern RT_MODEL_bms_Slave_T *const bms_Slave_M;

#endif

